// import {ShapeOptions} from "@antv/g6-core/lib/interface/shape";
import Shape from "@antv/g6-core/lib/element/shape";
export default function (){
    Shape.registerFactory('anchor', {
        defaultShapeType: 'marker',
        draw: (type, cfg, group) => {
            const timestamp = new Date().getTime();
            const id = "anchor" + timestamp;
            group.addShape('marker', {
                attrs: cfg.style,
                name:'anchor-shape',
                draggable: true,
                id: id
            })
            return group;
        },
    })
}